<template>
	<!-- 妇联首页 -->
	<view class="body">
		<myHeader :title="title"></myHeader>
		<uni-list>
			<uni-list-item title="月初计划" link="navigateTo" to="./monthStart/monthStartPlan"></uni-list-item>
			<uni-list-item title="月总计划" link="navigateTo" to="./monthEnd/monthEndPlan"></uni-list-item>
			<uni-list-item  title="周例会" link="navigateTo" to="./weekly/weeklyMeeting"></uni-list-item>
			<uni-list-item  title="团队信息" link="navigateTo" to="./team/teamIndex"></uni-list-item>
		</uni-list>
	</view>
</template>

<script>
	import myHeader from '../components/head.vue'
	export default {
		data() {
			return {
				title: '妇联',
				// 当前用户角色
				currentRoleCode: [],
			}
		},
		mounted() {
			this.getLoginUserRoles();
		},
		methods: {
			// 获取登录用户角色
			getLoginUserRoles() {
				let _this = this;
				uni.getStorage({
					key: 'user',
					success(e) {
						let arr = [];
						for (let item of e.data.role) {
							if (null != item.roleCode) {
								_this.currentRoleCode.push(item.roleCode)
								if (item.roleCode == 'fl-leader') {
									_this.isLeader = true;
								}
							}
						}
					}
				})
			},
		},
		components: {
			myHeader
		},
	}
</script>

<style>
</style>
